<!--{include manage_header}-->
<div class="place">
    <span>位置：</span>
    <ul class="placeul">
    <li><a href="/manage/partner/index.php">商家管理</a></li>
    <li><a href="/manage/partner/index.php">商家列表</a></li>
	<li style="float:right;  font-size:22px; ">
	 <a href="javascript::" style="padding-right:30px;color:#3B95C8;">
    <!--{if $_SESSION['ali_token']}-->${mb_strimwidth($login_user['realname'],0,10)}<!--{else}-->${mb_strimwidth($login_user['username'],0,10)}<!--{/if}-->
	</a> </li>
    </ul>
</div>
<div id="bdw" class="bdw">
<div id="bd" class="cf">
<div id="coupons">
	<!--<div class="dashboard" id="dashboard">
		<ul>${mcurrent_partner('index')}</ul>
	</div>-->
    <div id="content" class="coupons-box clear mainwide">
		<div class="box clear">
            <div class="box-top"></div>
            <div class="box-content">
                <div class="head">
                    <div class="formtitle"><span>商家列表</span></div>
					<ul class="filter"><li><!--{if is_manager(1)}--><form method="get">商家名称：<input type="text" name="ptitle" class="h-input" value="${htmlspecialchars($ptitle)}" >&nbsp;<select name="open" class="h-input"><option value="0">全部</option>${Utility::Option($option_open, $open)}</select>&nbsp;<select name="city_id" class="h-input"><option value="0">全部城市</option>${Utility::Option(option_category('city'), $city_id)}</select>&nbsp;<select name="group_id" class="h-input"><option value="0">全部分类</option>${Utility::Option(option_category('partner'), $group_id)}</select>&nbsp;<input type="submit" value="筛选" class="formbutton"  style="padding:1px 6px;"/></form></li></ul>
				</div>
                <div class="sect">
					<table id="orders-list" cellspacing="0" cellpadding="5" border="1" bordercolor="#89B4D6" style="width:99%" class="coupons-table">
					<tr><th width="40">ID</th><th width="320">名称</th><th width="60">分类</th><th width="120">联系人</th><th width="130">电话号码</th><th width="60">展示</th><th width="40">排序</th><th width="100">操作</th></tr>
					<!--{loop $partners $index $one}-->
					<tr ${$index%2?'':'class="alt"'} id="team-list-id-{$one['id']}">
						<td>{$one['id']}</td>
						<td style="text-align:left;"><a class="deal-title" href="/manage/partner/edit.php?id={$one['id']}">{$one['title']}</a></td>
						<td nowrap>{$groups[$one['group_id']]}<br/>{$cities[$one['city_id']]}</td>
						<td nowrap>{$one['contact']}</td>
						<td nowrap>{$one['phone']}<br/>{$one['mobile']}</td>
						<td nowrap>{$one['open']}</td>
						<td nowrap>{$one['head']}</td>
						<td class="op" nowrap><a href="/manage/partner/edit.php?id={$one['id']}">编辑</a>｜<a href="/ajax/manage.php?action=partnerremove&id={$one['id']}" class="ajaxlink" ask="确定删除本商户？">删除</a>｜
						<!-- 商家自助插件之结算插件-->
						<!--${$income = Table::Count('partnerincome', array('state' => '1','partner_id' => $one['id'],));}-->
						<a href="/manage/partner/income/index.php?id={$one['id']}">结算</a>
						<!--{if $income}-->(<a href="/manage/partner/income/detail.php?id={$one['id']}&state=1">待结算</a>{$income})<!--{/if}-->
						</td>
					</tr>
					<!--{/loop}-->
					<tr><td colspan="8">{$pagestring}</td></tr>
					<!--{else}-->
					<form method="get">商家名称：<input type="text" name="ptitle" class="h-input" value="${htmlspecialchars($ptitle)}" >&nbsp;<select name="open" class="h-input">${Utility::Option($option_open, $open, '展示')}</select>&nbsp;<select name="city_id" class="h-input"><!--{loop $allcities $index $city}-->
							<!--{if $city['id']==$login_user['city_id'] }-->
							<option  value="{$city['id']}"<!--{if $city['id']==$team['city_id'] }--> selected<!--{/if}-->>{$city['name']}</option>
							<!--{/if}-->
							<!--{/loop}--></select>&nbsp;<select name="group_id" class="h-input">${Utility::Option(option_category('partner'), $group_id, '全部分类')}</select>&nbsp;<input type="submit" value="筛选" class="formbutton"  style="padding:1px 6px;"/></form></li></ul>
				</div>
                <div class="sect">
					<table id="orders-list" cellspacing="0" cellpadding="5" border="1" bordercolor="#89B4D6" style="width:99%" class="coupons-table">
					<tr><th width="40">ID</th><th width="320">名称</th><th width="60">分类</th><th width="120">联系人</th><th width="130">电话号码</th><th width="60">展示</th><th width="40">排序</th><th width="100">操作</th></tr>
					<!--{loop $partnerss $index $one}-->
					<tr ${$index%2?'':'class="alt"'} id="team-list-id-{$one['id']}">
						<td>{$one['id']}</td>
						<td style="text-align:left;"><a class="deal-title" href="/manage/partner/edit.php?id={$one['id']}">{$one['title']}</a></td>
						<td nowrap>{$groups[$one['group_id']]}<br/>{$cities[$one['city_id']]}</td>
						<td nowrap>{$one['contact']}</td>
						<td nowrap>{$one['phone']}<br/>{$one['mobile']}</td>
						<td nowrap>{$one['open']}</td>
						<td nowrap>{$one['head']}</td>
						<td class="op" nowrap><a href="/manage/partner/edit.php?id={$one['id']}">编辑</a>｜<a href="/ajax/manage.php?action=partnerremove&id={$one['id']}" class="ajaxlink" ask="确定删除本商户？">删除</a>｜
						<!-- 商家自助插件之结算插件-->
						<!--${$income = Table::Count('partnerincome', array('state' => '1','partner_id' => $one['id'],));}-->
						<a href="/manage/partner/income/index.php?id={$one['id']}">结算</a>
						<!--{if $income}-->(<a href="/manage/partner/income/detail.php?id={$one['id']}&state=1">待结算</a>{$income})<!--{/if}-->
						</td>
					</tr>
					<!--{/loop}-->
					<tr><td colspan="8">{$pagestrings}</td></tr>
					<!--{/if}-->
                    </table>
				</div>
            </div>
            <div class="box-bottom"></div>
        </div>
    </div>
</div>
</div> <!-- bd end -->
</div> <!-- bdw end -->

<!--{include manage_footer}-->
